<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script src="../js/vue.js" type="text/javascript" charset="utf-8"></script>
	</head>
	<body>
		<div id="app">
			<span v-if="isUser"><label for="username">用户账号：</label><input type="text" name="" id="username" value="" placeholder="用户账号" key="uername"/></span>
			<span v-else="isUser"><label for="email">用户邮箱：</label><input type="text" name="" id="email" value="" placeholder="用户邮箱" key="email"/></span>
			<button @click="qihuan">切换类型</button>
		</div>
	</body>
	<script type="text/javascript">
		const app = new Vue({
			el:'#app',
			data:{
				isUser:true
			},
			methods:{
				qihuan(){
					this.isUser = !this.isUser
				}
			}
		})
	</script>
</html>
